﻿using GPS.DataAccessLayer;
using PagedList;
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace GPS.ENTITYS
{
    public class ViewModelDDTTN_KQTN
    {
        public int? Page { get; set; }
        public string pDVGTVT_MA { get; set; }
        public string pKH_MA { get; set; }
        public string pKH_LOP_MA { get; set; }
        public string pHV_MA { get; set; }
        public string pHV_HOTEN { get; set; }
        public string pHV_CMND { get; set; }
        public string pHANG_DT { get; set; }
        public decimal? pSO_QD_TN { get; set; }

        public Nullable<System.DateTime> pNGAY_KQTN_TUNGAY { get; set; }
        public Nullable<System.DateTime> pNGAY_KQTN_DENNGAY { get; set; }

        public IPagedList<ModelDDTTN_KQTN> SearchResults { get; set; }

    }

    public class ModelDDTTN_KQTN
    {

        public string HV_MA { get; set; }
        public string HV_DVGTVT_MA { get; set; }
        public string HV_KH_MA { get; set; }
        public string HV_KH_TEN { get; set; }
        public string HV_HO_TEN { get; set; }
        public string HV_DVGTVT_TEN { get; set; }
        public string HV_GIOITINH { get; set; }
        public string HV_NGAYSINH { get; set; }
        public decimal? DTTN_ID { get; set; }

        public decimal? DTTN_QD_ID { get; set; }
        public string DTTN_HGPLX_MA { get; set; }
        public decimal? ID { get; set; }
        public decimal? DTTN_KQTN_DTTN_ID { get; set; }

        public string DTTN_KQTN_DVGTVT_MA { get; set; }
        public string DTTN_KQTN_KH_MA { get; set; }
        public string DTTN_KQTN_HV_MA { get; set; }

        private DateTime? _DTTN_KQTN_NGAYTN;
        [DisplayFormat(DataFormatString = "{0:dd/MM/yyyy}",
               ApplyFormatInEditMode = true)]
        public System.DateTime? DTTN_KQTN_NGAYTN
        {
            get { return _DTTN_KQTN_NGAYTN ?? DateTime.Now; }
            set { _DTTN_KQTN_NGAYTN = value; }
        }
        public string DTTN_KQTN_VANG_LT { get; set; }

        [DisplayFormat(DataFormatString = "{0:0.00}", ApplyFormatInEditMode = true)]
        public decimal? DTTN_KQTN_LT { get; set; }
        public string DTTN_KQTN_LT_SHV_MA { get; set; }
        public string DTTN_KQTN_NXSHV_LT { get; set; }
        public string DTTN_KQTN_VANG_TH { get; set; }

        [DisplayFormat(DataFormatString = "{0:0.00}", ApplyFormatInEditMode = true)]
        public decimal? DTTN_KQTN_TH { get; set; }
        public string DTTN_KQTN_TH_SHV_MA { get; set; }
        public string DTTN_KQTN_NXSHV_TH { get; set; }
        public string DTTN_KQTN_VANG_TD { get; set; }

         [DisplayFormat(DataFormatString = "{0:0.00}", ApplyFormatInEditMode = true)]
        public decimal? DTTN_KQTN_TD { get; set; }
        public string DTTN_KQTN_TD_SHV_MA { get; set; }
        public string DTTN_KQTN_NXSHV_TD { get; set; }
        public string DTTN_KQTN_VANG_CC { get; set; }

        [DisplayFormat(DataFormatString = "{0:0.00}", ApplyFormatInEditMode = true)]
        public decimal? DTTN_KQTN_CC { get; set; }
        public string DTTN_KQTN_CC_SHV_MA { get; set; }
        public string DTTN_KQTN_NXSHV_CC { get; set; }
        public decimal? DTTN_KQTN_ID_XEPHANG { get; set; }

        [DisplayFormat(DataFormatString = "{0:0.00}", ApplyFormatInEditMode = true)]
        public decimal? DTTN_KQTN_TONG { get; set; }

        [DisplayFormat(DataFormatString = "{0:0.00}", ApplyFormatInEditMode = true)]
        public decimal? DTTN_KQTN_TB { get; set; }
        public string DTTN_KQTN_MOTA { get; set; }
        public Nullable<System.DateTime> DTTN_KQTN_NGAYNHAP { get; set; }
        public string DTTN_KQTN_NGUOINHAP { get; set; }
        public Nullable<System.DateTime> DTTN_KQTN_NGAYSUA { get; set; }
        public string DTTN_KQTN_NGUOISUA { get; set; }

        [DisplayFormat(DataFormatString = "{0:0.00}", ApplyFormatInEditMode = true)]
        public decimal? DTTN_KQTN_TBC { get; set; }

        [DisplayFormat(DataFormatString = "{0:0.00}", ApplyFormatInEditMode = true)]
        public decimal? DTTN_KQTN_TKKH { get; set; }

    }
}
